package com.leo.service.impl;

import com.leo.bean.Student;
import com.leo.dao.StudentMapper;
import com.leo.service.IStudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author wangss
 */
@Service("studentService")
public class StudentServiceImpl implements IStudentService {
    @Autowired
    private StudentMapper studentMapper;

    @Override
    public int add(Student student) {
        return this.studentMapper.add(student);
    }

    @Override
    public int update(Student student) {
        return this.studentMapper.update(student);
    }

    @Override
    public int deleteBysno(String sno) {
        return this.studentMapper.deleteBysno(sno);
    }

    @Override
    public Student queryStudentBySno(String sno) {
        return this.studentMapper.queryStudentBySno(sno);
    }

    @Override
    public List<Student> queryStudent() {
        return studentMapper.queryStudent();
    }

    @Override
    public List<Student> queryStudentGlobal() {
        return studentMapper.queryStudentGlobal();
    }

    @Override
    public int addDynamic(Student student) {
        return studentMapper.addDynamic(student);
    }

}
